﻿using System.Web;
using System.Text;
using System.IO;
using System.Net;
using System;
using System.Collections.Generic;

namespace Utility.Pay.Alipay.App
{
    /// <summary>
    /// 类名：Config
    /// 功能：基础配置类
    /// 详细：设置帐户有关信息及返回路径
    /// 版本：3.3
    /// 日期：2012-07-05
    /// 说明：
    /// 以下代码只是为了方便商户测试而提供的样例代码，商户可以根据自己网站的需要，按照技术文档编写,并非一定要使用该代码。
    /// 该代码仅供学习和研究支付宝接口使用，只是提供一个参考。
    /// 
    /// 如何获取安全校验码和合作身份者ID
    /// 1.用您的签约支付宝账号登录支付宝网站(www.alipay.com)
    /// 2.点击“商家服务”(https://b.alipay.com/order/myOrder.htm)
    /// 3.点击“查询合作者身份(PID)”、“查询安全校验码(Key)”
    /// </summary>
    public class Config
    {
        #region 字段
        public static string app_id = "2088121394851211";
        public static string method = "alipay.trade.app.pay";
        public static string format = "JSON";
        public static string charset = "utf-8";
        public static string sign_type = "RSA";
        public static string sign = "";
        public static string timestamp = "2014-07-24 03:07:50";
        public static string version = "1.0";
        public static string notify_url = "";
        public static string biz_content = "";

        public static string private_key = "";
        public static string public_key = "";

        #endregion


        #region 字段
        private static string partner = "";
    
        private static string input_charset = "";
      
        #endregion


        static Config()
        {
            //↓↓↓↓↓↓↓↓↓↓请在这里配置您的基本信息↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓

            //商户的私钥
            private_key = @"MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBAPTc/3vnLy8SnJvC
zTfKz8nhrXgdeG/ZcVOvAHvDKnDWjJ+FjW8ZYKtLzrrpkiCKyJNJUqdKWO0I2Mvi
KIlu1IhGK1JG79cuwaT/TkStkRKDFdDaZ4Tm1ln3spNxgiXx+bRKsqHaDCz8135A
77ZwlOckrT2nvcen/LT3K9S+Rw4lAgMBAAECgYEA6857901+wf1RdisWSFl227sK
vDbdShGEMovAkm8zyvDDAciymMA+uRfLIXNX9yDP4g9lmpddpf+0EDxev2NNJYDs
UhRrYfAMuKkUPAcHc01AnQTWexB/ISRFOIlWDJyPw8Ps+hAFj8HKjmV43tjlG6BX
0yxGIL/toQdWUkITS+ECQQD+XbZdYonw/SbF/bh8duG3i1anj5XQPFySWsy5O+QF
PQ7XdDsp0wGld+1jOtbjtYR0BBxrYZFZxQ2mUw9GxmnJAkEA9m+or7dvrkzw+Z3B
3NMI/RNm5bVc+rn2X3jY7QkLnRRS+v16NPbrhf6DFC87VdaJasEF3TEoy0byGKqv
ru2vfQJAFxvob39+TLiTBzXPxu79/rDYBI0U7UAuoNVC+CkqxBcR/B0BKwGSirfk
hzlXQITDLc8Zzd+lVuSCIvQ01Rc9kQJAZNPekrZczVXRqm+vZ+g4X0NW8Fk6B6Oa
eAl7x8/Rnp04LlUTcSQtzQ8LFnEUt9QlOTZsbcm1RSZr20fKxameCQJARivfkKu0
7wz8NnqgO/Nfy5wQwpsoVE6luxaMorRvSYQiapHwagmzvusFQEN5xjjXckRH+0T+
MytQWylOxNAAnw==";

            //支付宝的公钥，无需修改该值
            public_key = @"MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDDI6d306Q8fIfCOaTXyiUeJHkrIvYISRcc73s3vF1ZT7XN8RNPwJxo8pWaJMmvyTn9N4HQ632qJBVHf8sxHi/fEsraprwCtzvzQETrNRwVxLO5jVmRGi60j8Ue1efIlzPXV9je9mkjzOmdssymZkh2QhUrCmZYI/FCEa3/cNMW0QIDAQAB";

            //↑↑↑↑↑↑↑↑↑↑请在这里配置您的基本信息↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑

        }

        #region 属性
        /// <summary>
        /// 获取或设置合作者身份ID
        /// </summary>
        public static string Partner
        {
            get { return partner; }
            set { partner = value; }
        }

        /// <summary>
        /// 获取或设置商户的私钥
        /// </summary>
        public static string Private_key
        {
            get { return private_key; }
            set { private_key = value; }
        }

        /// <summary>
        /// 获取或设置支付宝的公钥
        /// </summary>
        public static string Public_key
        {
            get { return public_key; }
            set { public_key = value; }
        }

        /// <summary>
        /// 获取字符编码格式
        /// </summary>
        public static string Input_charset
        {
            get { return input_charset; }
        }

        /// <summary>
        /// 获取签名方式
        /// </summary>
        public static string Sign_type
        {
            get { return sign_type; }
        }
        #endregion

    }
}
